package com.kid.keep.dao.app;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.kid.keep.po.App;
import org.springframework.stereotype.Repository;

/**
 * @Description App dao
 * @Author JOHN
 * @Create 2019-01-10
 * @Since 1.0.0
 */
@Repository
public class AppRepository extends ServiceImpl<IAppMapper, App> implements IAppRepository {

    @Override
    public App findByWxAppIdAndDataStatus(String wxAppId, Integer dataStatus) {
        return this.baseMapper.selectOne(new QueryWrapper<App>().lambda().eq(App::getDataStatus, dataStatus).eq(App::getWxAppId, wxAppId));
    }
}


